package com.example.gamestore.service.imp;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.example.gamestore.Bean.Detail;
import com.example.gamestore.mapper.DetailMapper;
import com.example.gamestore.service.DetailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.RequestParam;

@Service
public class DetailServiceImp implements DetailService {
    @Autowired
    private DetailMapper detailMapper;

    @Override
    public Detail selectdetailbygameid(Integer gameid) {
        LambdaQueryWrapper<Detail> wrapper=new LambdaQueryWrapper<>();
        wrapper.eq(Detail::getGameid,gameid);
        Detail detail = detailMapper.selectOne(wrapper);
        return detail;
    }
}
